#pragma strict
//////////////////////////////////////////////////////
///射线工具.
//////////////////////////////////////////////////////
/**检测的距离*/
var distance:float = Mathf.Infinity;

var target:Transform;
//射线碰撞引用
private var hit:RaycastHit;

function Start(){
	hit = RaycastHit();
	if(! target){
		target = transform;
	}
}

function FixedUpdate(){
	Physics.Raycast(target.position,target.forward,hit,distance);
}

function Get():RaycastHit{
	return hit;
}

